import { createRouter, createWebHashHistory, RouteRecordRaw } from "vue-router";
import layout from '@/layout/index.vue'

export const routerList = [
	{
		path: '/',
		component: layout,
		redirect: '/blll',
		meta:{
			title:'波浪理论',
			icon: 'icon-weilaisizhouyubaochanpin'
		},
		children: [
			{
				path: '/czsc',
				name: 'czsc',
				component: () => import('@/views/czsc/index.vue'),
				meta: {
					title: '缠中说禅',
				}
			},
			{
				path: '/blll',
				name: 'blll',
				component: () => import('@/views/blll/index.vue'),
				meta: {
					title: '趋势',
				}
			},
			{
				path: '/guibi',
				name: 'guibi',
				component: () => import('@/views/guibi/index.vue'),
				meta: {
					title: '规避',
				}
			},
			{
				path: '/gegu',
				name: 'gegu',
				component: () => import('@/views/gegu/index.vue'),
				meta: {
					title: '选股',
				}
			},
		]
	},
	{
		path: '/kjds',
		component: layout,
		redirect: '/kjds',
		meta:{
			title:'跨境电商',
			icon: 'icon-weilaisizhouyubaochanpin'
		},
		children: [
			{
				path: '/smskjds',
				name: 'smskjds',
				component: () => import('@/views/kjds/smskjds.vue'),
				meta: {
					title: '什么是跨境电商',
				}
			},
			{
				path: '/fenlei',
				name: 'fenlei',
				component: () => import('@/views/kjds/fenlei.vue'),
				meta: {
					title: '独立站、国际站',
				}
			},
			{
				path: '/rhdj',
				name: 'rhdj',
				component: () => import('@/views/kjds/rhdj.vue'),
				meta: {
					title: '如何搭建',
				}
			},
			{
				path: '/rhtg',
				name: 'rhtg',
				component: () => import('@/views/kjds/rhtg.vue'),
				meta: {
					title: '如何推广',
				}
			},
			{
				path: '/rhyy',
				name: 'rhyy',
				component: () => import('@/views/kjds/rhyy.vue'),
				meta: {
					title: '如何运营',
				}
			},
			{
				path: '/cjwt',
				name: 'cjwt',
				component: () => import('@/views/kjds/cjwt.vue'),
				meta: {
					title: '常见问题',
				}
			},
			{
				path: '/xzcp',
				name: 'xzcp',
				component: () => import('@/views/kjds/xzcp.vue'),
				meta: {
					title: '产品选择',
				}
			},
		]
	},
	{
		path: '/',
		component: layout,
		redirect: '/home',
		children: [
			{
				path: '/home',
				name: 'home',
				component: () => import('@/views/home/index.vue'),
				meta: {
					title: '主页啊',
					icon: 'icon-weilaisizhouyubaochanpin'
				}
			}
		]
	},
	// {
	// 	path: '/avoidance',
	// 	component: layout,
	// 	redirect: '/avoidance/index',
	// 	children: [
	// 		{
	// 			path: '/avoidance/index',
	// 			name: 'avoidance',
	// 			component: () => import('@/views/avoidance/index.vue'),
	// 			meta: {
	// 				title: '选股避坑',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/mainforce',
	// 	component: layout,
	// 	redirect: '/mainforce/index',
	// 	children: [
	// 		{
	// 			path: '/mainforce/index',
	// 			name: 'mainforce',
	// 			component: () => import('@/views/mainforce/index.vue'),
	// 			meta: {
	// 				title: '主力行为',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/behavior',
	// 	component: layout,
	// 	redirect: '/behavior/index',
	// 	children: [
	// 		{
	// 			path: '/behavior/index',
	// 			name: 'behavior',
	// 			component: () => import('@/views/behavior/index.vue'),
	// 			meta: {
	// 				title: '散户行为',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/analysis',
	// 	component: layout,
	// 	redirect: '/analysis/index',
	// 	children: [
	// 		{
	// 			path: '/analysis/index',
	// 			name: 'analysis',
	// 			component: () => import('@/views/analysis/index.vue'),
	// 			meta: {
	// 				title: '关于方向',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/band',
	// 	component: layout,
	// 	redirect: '/band/index',
	// 	children: [
	// 		{
	// 			path: '/band/index',
	// 			name: 'band',
	// 			component: () => import('@/views/band/index.vue'),
	// 			meta: {
	// 				title: '过程理解',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/trading',
	// 	component: layout,
	// 	redirect: '/trading/index',
	// 	children: [
	// 		{
	// 			path: '/trading/index',
	// 			name: 'trading',
	// 			component: () => import('@/views/trading/index.vue'),
	// 			meta: {
	// 				title: '交易系统',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/Invest',
	// 	component: layout,
	// 	redirect: '/Invest/index',
	// 	children: [
	// 		{
	// 			path: '/Invest/index',
	// 			name: 'Invest',
	// 			component: () => import('@/views/Invest/index.vue'),
	// 			meta: {
	// 				title: '投资误区',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/humanity',
	// 	component: layout,
	// 	redirect: '/humanity/index',
	// 	children: [
	// 		{
	// 			path: '/humanity/index',
	// 			name: 'humanity',
	// 			component: () => import('@/views/humanity/index.vue'),
	// 			meta: {
	// 				title: '反人性',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/opportunity',
	// 	component: layout,
	// 	redirect: '/opportunity/index',
	// 	children: [
	// 		{
	// 			path: '/opportunity/index',
	// 			name: 'opportunity',
	// 			component: () => import('@/views/opportunity/index.vue'),
	// 			meta: {
	// 				title: '关于机会',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/warehouse',
	// 	component: layout,
	// 	redirect: '/warehouse/index',
	// 	children: [
	// 		{
	// 			path: '/warehouse/index',
	// 			name: 'warehouse',
	// 			component: () => import('@/views/warehouse/index.vue'),
	// 			meta: {
	// 				title: '仓位管理',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/Wheeling',
	// 	component: layout,
	// 	redirect: '/Wheeling/index',
	// 	children: [
	// 		{
	// 			path: '/Wheeling/index',
	// 			name: 'Wheeling',
	// 			component: () => import('@/views/Wheeling/index.vue'),
	// 			meta: {
	// 				title: '轮动关系',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/strength',
	// 	component: layout,
	// 	redirect: '/strength/index',
	// 	children: [
	// 		{
	// 			path: '/strength/index',
	// 			name: 'strength',
	// 			component: () => import('@/views/strength/index.vue'),
	// 			meta: {
	// 				title: '强弱分析法',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/summarize',
	// 	component: layout,
	// 	redirect: '/summarize/index',
	// 	children: [
	// 		{
	// 			path: '/summarize/index',
	// 			name: 'summarize',
	// 			component: () => import('@/views/summarize/index.vue'),
	// 			meta: {
	// 				title: '盘感心得',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
	// {
	// 	path: '/prediction',
	// 	component: layout,
	// 	redirect: '/prediction/index',
	// 	children: [
	// 		{
	// 			path: '/prediction/index',
	// 			name: 'prediction',
	// 			component: () => import('@/views/prediction/index.vue'),
	// 			meta: {
	// 				title: '短期未来预测',
	// 				icon: 'icon-weilaisizhouyubaochanpin'
	// 			}
	// 		}
	// 	]
	// },
]

const routes: Array<RouteRecordRaw> = [
	...routerList,
	{
		path: '/404',
		name: '404',
		component: () => import('@/views/errorPage/404.vue')
	},
	{
		path: '/:pathMatch(.*)',
		redirect: '/404',
		component: () => import('@/views/errorPage/404.vue'),
		children: []
	}
];

const router = createRouter({
	history: createWebHashHistory(`/doc/`),
	routes,
});

export default router;
